You can connect api authentication with OAuth2 Provider.
The "OAuth2 Provider for Odoo" module enhances the functionality of the Odoo ERP system by transforming it into an OAuth2 provider.